package com.malamute.core.entity;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.MappedSuperclass;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * @author AceGuan gjybst@163.com
 * @description 实体的基础属性
 * @date 2012-2-4 下午03:39:35
 * @version v1.0
 */
@MappedSuperclass
public abstract class BaseEntity implements Serializable {
	@Id
	@GeneratedValue(strategy = GenerationType.AUTO)
	private Integer id;// 主键
	private String creator;// 创建者
	private String modify;// 修改者
	@Temporal(TemporalType.TIMESTAMP)
	private Date createTime = new Date();// 创建时间
	@Temporal(TemporalType.TIMESTAMP)
	private Date modifyTime;// 修改时间
	
	

	/**
	 * 获取createTime
	 * 
	 * @return createTime
	 */

	public Date getCreateTime() {
		return createTime;
	}

	/**
	 * 获取id
	 * 
	 * @return id
	 */

	public Integer getId() {
		return id;
	}

	/**
	 * 设置id
	 * 
	 * @param id
	 */
	public void setId(Integer id) {
		this.id = id;
	}

	/**
	 * 获取creator
	 * 
	 * @return creator
	 */

	public String getCreator() {
		return creator;
	}

	/**
	 * 设置creator
	 * 
	 * @param creator
	 */
	public void setCreator(String creator) {
		this.creator = creator;
	}

	/**
	 * 获取modify
	 * 
	 * @return modify
	 */

	public String getModify() {
		return modify;
	}

	/**
	 * 设置modify
	 * 
	 * @param modify
	 */
	public void setModify(String modify) {
		this.modify = modify;
	}

	/**
	 * 获取modifyTime
	 * 
	 * @return modifyTime
	 */

	public Date getModifyTime() {
		return modifyTime;
	}

	/**
	 * 设置modifyTime
	 * 
	 * @param modifyTime
	 */
	public void setModifyTime(Date modifyTime) {
		this.modifyTime = modifyTime;
	}

	/**
	 * 设置createTime
	 * 
	 * @param createTime
	 */
	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

}
